Problems with c# zxing port - c#

first excuse me for the bad english, then i wanna ask you a piece of advice to solve this problem. I'm trying to use zxing C# port.
I tried then to parse this image:
bar code http://img168.imageshack.us/img168/2633/0003gby.jpg
at zxing.org which recognized it.
The little program I wrote, instead produced a ReaderException.
Any ideas, or anybody who wrote a piece of code which does the job?

I realize this is a bit old, but I've just tried using ZXing's C# port for the first time, and I've found that I have to use the TRY_HARDER DecodeHintType to get the barcode to read.
In the code, it looks like it's expecting the image provided to be a region around the barcode itself, so it starts looking in the middle. Setting the TRY_HARDER flag makes it search the entire page.

Related

Certificate Transparency Logs for C#

Currently working on a certificate transparency logs. My goal is to read each log just like what CertStream - (Open the fire hose button) did, my boss wants to create another one that is written in C#. Just a simple code to parse the logs can really help me. Not necessarily as fancy as CertStream does its stuff.
These are the following links/APIs that I've read:
(API's from Google or related)
https://ct.googleapis.com/pilot/ct/v1/get-sth
https://ct.googleapis.com/logs/argon2020/ct/v1/get-entries?start=20200201&end=20200205
https://www.rfc-editor.org/rfc/rfc6962
Valuable info:
https://certstream.calidog.io/
https://stackoverflow.com/questions/59772797/cant-parse-precertificate-from-certificate-transparency-log
For the code I started,
byte[] byte_LeafInput = Convert.FromBase64String(leaf_input);
byte[] byte_extradata = Convert.FromBase64String(extra_data);
string strLeafInput = Encoding.UTF8.GetString(byte_LeafInput);
string strExtraData = Encoding.UTF8.GetString(byte_extradata);
But it only shows some gibberish data with few readable words.
Any codes or libraries that can help me with that? Upon searching, I found so many codes written in different languages like Python, Go, etc., but based on what I understand in their code, they are also using libraries which is not available in NuGet. X509Certificate might be useful but I don't know how to use it in this case.
Any lead would really be appreciated. Thank you.
Upon searching for a long time. My boss advised me to get the logs and parse it through Python and save that in a text file or csv. After that, my program in C# can use all functions to analyze the information in the created text file. I guess using the current wheel is more efficient than creating one. :)

BLE scanning and read value from pc, how can i solve 'unknown data' issue?

I'm a beginner in c#, I'd appreciate your help.
Here's what I use:
-nRF52840 dk (it is developed by segger embedded studio)
-pc bluetooth (window 10)
Im trying to create a program that scans Ble and receives a value(continuously sent by ble). I have been looking at the Windows-universal-samples.
but when i try to read value, it doesn't work.
enter image description here
How can i solve this problem? Thank you for reading it, and if you know how, please share it.
The LED Characteristic (0x1525) appears to be controlling LED 3 for the nordic_blinky example. My thought is that this might be a write only characteristic and so that is maybe why you are getting the error.
As others have pointed out, it is difficult to know with the little information you have shared. A link to the sample code you are following would be a helpful start.
Also, have you tested the nordic_blinky with general tools? For example, in chrome you can go to the URL: chrome://bluetooth-internals/#devices. It will tell you if the characteristic is readable and writable. Being able to share that would be useful information for others to help. If you are able to read or write in Chrome, then we can be more confident the issue is with your code. Again sharing it working in Chrome and your code that is failing will be helpful for others to assist as to where the issue might be.
Try these experiments and update the question would be my suggestion.

Capture Image using Microsoft LifeCam and C#

I have a Microsoft LifeCam and I want to Capture image using C# and use the image inside my application.
I have checked A previously asked question in SO but the link provided in first answer to OpenCV looks to be invalid ( I get "FORBIDDEN" response ).
I want to know if there is any Sample that I can use to learn and capture Image from LifeCam? And also I need the dll (s) for this.
Does anyone have any experience in this case?
Thanks to Sascha, ESCAPI Solution really helped, I used the ESCAPI.dll along with the C# wrapper to translate it to C# and it all went well.

C# Custom OCR that returns a formatted string

Just for my personal interest, I see from my research that it's not that easy to start your own OCR. However, I would like to hear ideas on how to achieve the challenge of not just recognising characters, but also giving back the results in the formatted string.
For example, I have an image of a table (imagine that it's an image with "|" and "_" being drawn straight lines):
|Number, AnotherNumber|Some Text|
|1,4 |Blah |
And after using a silent OCR, I get the result as "|Number, AnotherNumber|SomeText|\n|1,4|Blah|"
Any ideas of how could I achieve this, and what available tools/libraries I could make use of? I also would like to write this in C# with Visual Studio 2010. And ideally to work with PDFs but different image formats are fine. I've already looked at some, but they seem non-compatible as they use C++ or C.
Thank you.
Alina.
getting ocr libaries is quite hard (of course just if you dont pant to pay for it)
you could try this one, its not free but if you have office 2007:
http://www.codeproject.com/Articles/41709/How-To-Use-Office-2007-OCR-Using-C

What type of BarCode is this?

I am starting the process of writing an application, one part of which is to decode bar codes, however I'm off to a bad start. I am no bar code expert and this is not a common bar code type, so I'm in trouble. I cannot figure out what type of bar code this is, which I have to decode.
I have looked on Wikipedia and some other sites with visual descriptions of different types of bar codes (and how to identify them), however I cannot identify it. Please note that I have tried several free bar code decoding programs and they have all failed to decode this.
So here is a picture of that bar code:
alt text http://www.shrani.si/f/2B/4p/4UCVyP72/barcode.jpg
I hope one of you can recognize it. Also if anyone has worked with this before and knows of a library that can decode them (from an image), I'd love to hear about them.
I'm very thankful for any additional pointers I can receive. Thank you.
zbar thinks it's Code 128 but the decoded string is suspiciously different than the barcode's own caption. Maybe it's a charset difference?
~/src/zebra-0.5/zebraimg$ ./zebraimg ~/src/barcode/reader/barcode.jpg
CODE-128:10657958011502540742
scanned 1 barcode symbols from 1 images in 0.04 seconds
My old copy was called zebra but the library is now called zbar. http://sourceforge.net/projects/zbar/
I don't recognize this bar code - but here are a few sites that might help you (libraries etc.) - assuming you use C# and .NET (you didn't specify in your question):
http://www.idautomation.com/csharp/
http://www.bokai.com/barcode.net.htm
It looks a bit like Code 128 but http://www.onlinebarcodereader.com/ does not recognize it as such. Maybe the image quality isn't good enough.
If you are using Java:
http://code.google.com/p/zxing/
Open Source, supports multiple types of barcodes
A list of software can be found here:
http://www.dmoz.org/Computers/Software/Bar_Code/Decoding/
IANABCE (I Am Not A Barcode Expert), but looking at the barcodes here, I'd say this looks closest to the UCC/EAN-128 symbology, character set 'C'.
Do you know what the barcode is used for? What's the application domain?

Categories

Resources