Digital imaging

1 view
Skip to first unread message

Alan Davis

unread,
Jan 13, 2022, 6:59:26 AM1/13/22
to berke...@googlegroups.com
Hello to the BLUG.  For the past little bit I have been lurking, just watching the email stream.  I have a question or two, perhaps pertinent.  For now, I will stick with my experience trying to use cameras on microscopes, using GNU/Linux as the computer platform.  This could be a long tale, or, hopefully, more direct. 

I have three cameras plus a "smart" phone, all of which I have used on my microscope.  This is a relatively crude setup with a trinocular head.  Of the cameras I use, one of them is most problematic: a relatively cheap 21 megapixel "Industrial Microscope Camera,"  purchased on Ebay.  This camera is primarily an HDMI camera, controllable via a crude on-screen menu using a very cheap looking remote control.  When hooked up by USB2, it identifies itself as a "Venus" camera, the manufacturer being "Hayear."   Hayear offers software for GNU/Linux, similar to other microscope camera software as available, fof example, from AmScope, and others.  By way of comparison, I also have access to a It has a limited range of controls available to tthis and other, webcam type software I have use.  It seems to me that the API (probably the wrong term) built into firmware is limited in scope. 

By comparison I have access to a dedicated microscope camera, that identifies as "Novel", at 2 megapixel, with better "API" features (if that is the right term).  When the GNU/Linux program "guvcview" is used, controls include gain, sharpening, exposure, contrast, saturation, and more. 

I have learned that this area of work---whatever it is called, is not as well provided for as those softwares for "both Windows and MacOS."  I have used Windows and MacOS both, but I dont work that way.  So I'm stuck with what I can find.

I also have a Canon EOS mirrorless DSLR with an AmScope adapter, not optically optimal, but I can use the excellent GNU/Linux utility Entangle with it.  It's a little rough, but the programmer, Daniel Berringer (I think) has made some other amazingly useful software as well, and this one has the needed operational levers, if not all bells and whistles.  Actually it has some of these too! 

I hope, with all the hardware expertise of the group, someone can point to other approaches I have not tried.  For example, here is the big question: Can the controls of the more facile dedicated "Novel" camera be made to work with the Industrial Camera.  And why?  Actually there is a Windows/MacOS program for the Venus camera that has more controls.  On GNU/Linux, I think this has not been done.

I have not been participating in the group for a while.  Hopefully, I can find more time to attend in-person meetings.  Sundays are family time, that's my main excuse; also our family is on a swing shift schedule, all upside-down and backwards.  Who said that life only happens between 8 and 5 on weekdays? 

My best wishes to all members of this group.  May all be well and stay safe.  We are all vaccinated and boosted, and we do not fear the mask.

Alan Davis

--
 
      "As we enjoy great advantages from the inventions of others, we should be glad of an opportunity to serve others by any invention of ours, and this we should do freely and generously."   ---Benjamin Franklin

      "This ignorance about the limits of the earth's ability to absorb
       pollutants should be reason enough for caution in the release
       of polluting substances."
                   ---Meadows et al.   1972.  Limits to Growth.      (p. 81)       

tom r lopes

unread,
Jan 15, 2022, 12:49:13 AM1/15/22
to Alan Davis, BerkeleyLUG
On Thu, Jan 13, 2022 at 3:59 AM Alan Davis <alan3...@gmail.com> wrote:
Hello to the BLUG.  For the past little bit I have been lurking, just watching the email stream.  I have a question or two, perhaps pertinent.  For now, I will stick with my experience trying to use cameras on microscopes, using GNU/Linux as the computer platform.  This could be a long tale, or, hopefully, more direct. 

I have three cameras plus a "smart" phone, all of which I have used on my microscope.  This is a relatively crude setup with a trinocular head.  Of the cameras I use, one of them is most problematic: a relatively cheap 21 megapixel "Industrial Microscope Camera,"  purchased on Ebay.  This camera is primarily an HDMI camera, controllable via a crude on-screen menu using a very cheap looking remote control.  When hooked up by USB2, it identifies itself as a "Venus" camera, the manufacturer being "Hayear."   Hayear offers software for GNU/Linux, similar to other microscope camera software as available, fof example, from AmScope, and others.  By way of comparison, I also have access to a It has a limited range of controls available to tthis and other, webcam type software I have use.  It seems to me that the API (probably the wrong term) built into firmware is limited in scope. 

By comparison I have access to a dedicated microscope camera, that identifies as "Novel", at 2 megapixel, with better "API" features (if that is the right term).  When the GNU/Linux program "guvcview" is used, controls include gain, sharpening, exposure, contrast, saturation, and more. 

On Linux you would ID a USB device with the lsusb command.  The hardware ids tell you exactly what is connected.  

For example on my Ubuntu desktop: 

tom@tom-desktop:~$ lsusb
Bus 002 Device 002: ID 8087:0024 Intel Corp. Integrated Rate Matching Hub
Bus 002 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
Bus 001 Device 003: ID 046d:c52b Logitech, Inc. Unifying Receiver
Bus 001 Device 002: ID 8087:0024 Intel Corp. Integrated Rate Matching Hub
Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
Bus 004 Device 002: ID 046d:085e Logitech, Inc. Logitech BRIO
Bus 004 Device 001: ID 1d6b:0003 Linux Foundation 3.0 root hub
Bus 003 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub


So my camera is 046d:085e Logitech, Inc. Logitech BRIO  046d  means Logitech and 085e is the device

The capabilities of the cam in Linux can be seen from the v4l2-ctl command.  You don't say what distro you have but 
I remember you from before and recall that you run Manjaro. If so you can find this in the package 

Relevant Arch wiki page: webcam setup

My camera the Brio for example: 

tom@tom-desktop:~$ v4l2-ctl -l
                     brightness 0x00980900 (int)    : min=0 max=255 step=1 default=128 value=128
                       contrast 0x00980901 (int)    : min=0 max=255 step=1 default=128 value=128
                     saturation 0x00980902 (int)    : min=0 max=255 step=1 default=128 value=128
 white_balance_temperature_auto 0x0098090c (bool)   : default=1 value=1
                           gain 0x00980913 (int)    : min=0 max=255 step=1 default=0 value=0
           power_line_frequency 0x00980918 (menu)   : min=0 max=2 default=2 value=2
      white_balance_temperature 0x0098091a (int)    : min=2000 max=7500 step=10 default=4000 value=4000 flags=inactive
                      sharpness 0x0098091b (int)    : min=0 max=255 step=1 default=128 value=128
         backlight_compensation 0x0098091c (int)    : min=0 max=1 step=1 default=1 value=1
                  exposure_auto 0x009a0901 (menu)   : min=0 max=3 default=3 value=3
              exposure_absolute 0x009a0902 (int)    : min=3 max=2047 step=1 default=250 value=250 flags=inactive
         exposure_auto_priority 0x009a0903 (bool)   : default=0 value=1
                   pan_absolute 0x009a0908 (int)    : min=-36000 max=36000 step=3600 default=0 value=0
                  tilt_absolute 0x009a0909 (int)    : min=-36000 max=36000 step=3600 default=0 value=0
                 focus_absolute 0x009a090a (int)    : min=0 max=255 step=5 default=0 value=0 flags=inactive
                     focus_auto 0x009a090c (bool)   : default=1 value=1
                  zoom_absolute 0x009a090d (int)    : min=100 max=500 step=1 default=100 value=100
                      led1_mode 0x0a046d05 (menu)   : min=0 max=3 default=0 value=3
                 led1_frequency 0x0a046d06 (int)    : min=0 max=255 step=1 default=0 value=0

I find this camera on the web.  Is that the one?  If so the manufacturer even states that few controls are possible from USB.  

You may need to connect via HDMI to get what you want.  But if you need to have it display to your Linux desktop then maybe invest in 
an hdmi capture card.  I don't have any direct experience with hdmi capture.  I do like to watch some electronics repair on Youtube and 
they typically use hdmi cameras and capture with a pci card.  Louis Rossmann for example is a professional youtuber and he uses a 
thousand dollar capture card pci.  But you can probably get something reasonable less than $100, especially since you aren't doing 4k.  
I have just a $20 Amazon cheepo usb hdmi capture.  It works good for what I need which is to stream video from a Raspberry Pi to a 
Jitsi meeting.  

Thomas

P.S.  What kind of microscopy are you doing?  I believe there is a Bay Area microscopy group.  
Reply all
Reply to author
Forward
0 new messages