2013-11-04

BMPCC LANC and Sysclk DX (USBee DX clone)



I received my Sysclk DX from China. It's an affordable clone of the USBee DX.
A 2 channel USB Mixed Signal oscilloscope paired with an integrated 16 channel logic analyser.
The first task I'm giving it is to analyse the LANC protocol on the Blackmagic Pocket Cinema Camera.
Why? Because I need to have a way to meassure what's supposed to be on the wire and what is actually there to implement LANC into an Atmel microcontroller and build a better LANC remote. ;)

First try:
On a breadboard I pulled the data line high and tried to analyse the signal. The camera is supposed to send data packets... absolutely no luck. :(

Second try:
I put the breadboard in between a working LANC remote and the camera and ran the logic analyser.
I may be doing something wrong but I can't see anything on the wire. The LANC remote however works fine!

UPDATE: Third try:
I dumped the Sysclk DX and got my old Usbee AX and it worked fine.
I found the following LANC commans on the Blackmagic Pocket:
//LANC(0x18, 0x33); //send REC command to camera
//LANC(0x28, 0x45); //send MANUAL FOCUS FAR command to camera
//LANC(0x28, 0x47); //send MANUAL FOCUS NEAR command to camera
//LANC(0x28, 0x53); //send IRIS+ command to camera
//LANC(0x28, 0x55); //send IRIS- command to camera

LANC(0x28, 0x43); // AUTO FOCUS  
Update: Blackmagic answered: IrisAutoAdjust =  0x28 0xAF
I search in the area of 0x55 and 0x47 but could not find anything that triggers auto iris or auto focus.
Aparently these commands do exist but I don't know the command code.

UPDATE:
Using the code from "Control your camera" it seems to work more reliable when removing the -8ms adjsutment for the digitalWrite command and replacing that with a macro from here:

#define fastWrite(_pin_, _state_) ( _pin_ < 8 ? (_state_ ?  PORTD |= 1 << _pin_ : PORTD &= ~(1 << _pin_ )) : (_state_ ?  PORTB |= 1 << (_pin_ -8) : PORTB &= ~(1 << (_pin_ -8)  )))
// the macro sets or clears the appropriate bit in port D if the pin is less than 8 or port B if between 8 and 13


my send-byte routing now looks like this:
void send_8(char dat) {
  char abit;
  char index;
  for(index = 0; index <= 7; index++) {
  abit = ((dat>>index) & 0x01);
  if(abit==1) {
    fastWrite(cmdPin, HIGH);
  } else {
    fastWrite(cmdPin, LOW);
  }
  delayMicroseconds(bitDuration);
}

//Byte is written now put LANC line back to +5V
fastWrite(cmdPin, LOW);

}


Also: I can successfully power the Arduino Uno from the LANC cable.

2013-10-24

Soundproofing the TravelCNC


The TravelCNC already has an inner lining of Basotect acoustic foam on the inside.
(Not all of it mounted yet because I'll improve some of the cabling hidden below the foam.)
This helps a great deal with high frequencies.
For the low frequencies I have a heavy, 10mm thick rubber sheet below the actual machine.

It turns out that this is not enough. I get a great deal of vibration that can actually be felt on the wooden stage box.
Next idea: there are 4 bolts going through the rubber and mounting the machine to the case.
I'mm try to widen the holes in the wood and install sound insulating bolt anchor fittings to insulate the bolt from the hole in the wood.

...let's see of that helps.





2013-11-13 UPDATE
I finally finishd the sound proofing




2013-10-22

Fixing the 4th axis on the TravelCNC and breaking my tools


Since I mounted a larger stepper motor to the 4th axis on my TravelCNC (portable hobby sized CNC in a custom flight case), I needed to raise the 4th axis by 10mm.
Else the longer stepper would collide with the frame.




This means that the tailstock is now too low.

So yesterday and today I milled myself a spacer out of some wood to keep the tailstock at the correct height.



It worked...but when I tried to use it, I made a terrible mistake.
I wanted to use the edge finder to find the right and left edge of the cylinder I mounted.
I knew it was perfectly round, so the center of rotion would match the center of the cylinder.
....so I mounted my mechanical edge finder...switch on the spindle to rotate it slowly

...and forgot that the spindle was still set to 10'000RPM.
It ripped my trusted edge finder apart.

Now you can get mechanical edge finders for 3-4eur in China, no problem.
You can even get cool electronic ones for 10eur.
However all the mechanical ones are 10mm shank and the electronic ones 20mm shank.
The maximum my ER11 collets can mount is 7mm.

I would really like to modify one of these electronic ones. Attach it to the electronic probe input and find edges extremely accurately without jogging back and forth.
However the back is also the battery cover. So I can't simply mill it down from d=20mm to d=7mm. :/

2013-10-19

MY BMPCC review

I just received my Blackmagic Pocket Cinema Camera last night.
In this blog posting I'm trying to collect my findings about it to help others decide on it's maturity.

untested


  • LANC focus control
  • LANC IRIS control (command codes unknown)

confirmed features

  • LANC start+stop
  • very fine and organic grain

confirmed, known issues

  • very low audio levels with internal or external microphone (Sennheiser MKE400 with levels "+")
  • constant white noise in audio
  • Focus button is extremely slow (2-4 second for a Leica lens that focuses in less then 1/10s)
  • no OIS on 14-42PZ
  • extremely short battery life
  • seldom dropped frames (3-4 frames on a total of 45min of 1-5 minute recordings) using Patrion Memory EP-Series 64GB UHS-1 SD-card

new issues

  • 14-42PZ does not shut down properly on BMPCC (lens doesn't collapse)
  • LANC cannot control the zoom on the 14-42PZ, ,14-42 II, 42-175 PZ and 100-300 using the Manftotto 484LNC (my fault. DAQ states that ZOOM via LANC is unsupported. :( )

feature requests

  • manual aperture control in the menu
    • you can do that. You have to press IRIS and the up+down buttons right below. Imposible with one hand. Difficult with 2 hands.
  • display of remaining minutes on SD-card
  • audio levels
  • deletion of clips in camera
  • formating SD-cards in camera

Links 

2013-10-17

Tailstock height adapter for my TravelCNC

The original 4th axis on my TravelCNC was mounted so low, you can't even extend the arms of the chucks beyond the diameter of the chuck itself without hitting the table.
It was also so weak, that you could rotate it with 2 fingers while it tried to rotate the other way with all it's force.

So now I have a NEMA23 longneck stepper with tons of holding torque...and I can't mount it because it collides with the table.
Luckily it already came with a 10mm high alumimum plate to be mounted on the T-Slots.
What I did was to mill a small spacer out of wood to get the tailstock to the same Z+10mm height because obviously both have to match.

As it turned out, I had the wrong tool diameter in my CAM and it was 2mm too short.
..but that's easily fixed with hand tools while cutting it out.
(I don't want to cut it out with the CNC because I have no scrap-wood below it to ensure a flat surface.)


2013-09-27

The perfect multitool

I think I found the perfect multitool for me.

What I found I need are:
  • LED lamp
  • pliers
  • phillips #1 screwdriver
  • flat screwdriver
  • knife
  • sometimes a bottle opener (although Germans open bottles with just about everything...except bottle openers.)
  • wire strippers would be handy but not needed.
I like full sized multitools but they tend to stick out in an office environment, so I can't wear them all day (wich is kind of a point of having such a tool on your belt).
Instead I carry 3 tools:

The first thing I carry on my belt is a foldable and very tiny xacto-knife. Extremely tiny, extremely sharp and with a number of replacement blades inside. I think I'll keep that.
It's similar to this one except in color and name and that it comes with a tiny belt holster:





I had to ditch a small chinese tool at the airport, having forgotten to put it into the checked in luggage
(Not because of the knife...but because it had a screwdriver. Aparently airlines are afraid Germany Engineers can do just about anything given a screwdriver and duct tape.).
In San Francisco I got myself a Portland Coast  C2899.


I also carry a small 1xAAA flashlight but can't find a belt holster tiny enough for it.
The Coast was supposed to replace it because it already HAD a flashlight.
...only that it was way too weak, required a size of batteries you don't easily get in continental Europe and constantly empty because the button was accidentally pushed by just about anything in your pocket.
...and it didn't come with a belt holster.

Now I found something else.
A chinese dealer named Yuki Guan sells a RUISS RS1016A.
It doesn't show but he answered that it's also avaliable in black and it comes with a very sturdy belt holster.
It has the same, nice grip that the Portland Coast one has but the LED lamp is bigger and cannot be activated accidentally anymore.

custom XL45 pulley for 8mm D-shaped shaft



My CNC milling machine has a weak 4th axis.
I want to attach a larger stepper motor with seriously mor torque.
However that motor has a D-shaped 8mm shaft while an XL45T10 pulley always has a 6mm shaft.
I ordered a conventional one, hoping to drill it up but it was stuck in transit (damn Hermes. An envelope would have worked better.).
So I had to design a custom pulley that could me machined without a rotary axis (less of a top guard) and fits snugly onto an 8mm shaft.

In fact, I'm 3d printing a first one and plan to do the final one with a full sized top guard on the, thus fixed, 4th axis.


    2013-09-25

    Blown stepper driver

    After doing some test cuts yesterday I'm doing the first real milling on my TravelCNC today.
    I want to find out if it doesn't loose any steps now.

    First problem:
    after switching it on there was smoke any my Y-stepper driver went belly up.
    The FMD2740A stepper driver is rated  for 12-50V DC input.
    Internally they use an LM2576S-5.0 to generate 5V.
    Maximum input voltage 45V.
    ...They do not use the LM2576*HV*S-5.0 with a maximum input voltage of 60V.
    And I'm using a 48V power supply.
    ....go figure.


    Update: The chinese dealer very forthcoming and is even offering to pay for the repair (shipping to china and back to get a replacement with the same chip is expensive, time consuming and not a permanent solution).

    I now connected the Y stepper to the A channel, set MACH3 to interpret the A channel as  a linear axis and search&replaced the axis in the g-code.
    It's not cutting.....
    The operation will take 2x 1h . That should be enough to detect any lost steps. Particularly in Z.
    Touching the hand weels on the steppers there is no jittering. So it looks good.


    Update: Test was a SUCCESS. No lost steps whatsoever anymore!!! Very smooth operation for multiple hours and interrupted with shutting down the machine for a night before resuming.

    Update: My replacement FMD2740A died too. (during 30C3) Post mortem showed a bad solder joing on capacitor 1.

    Update:  2 other stepper drivers blown. Dealer "Thomas Wu" confesses they are only good up to 45V. Not 50V

    2013-09-24

    TravelCNC doing it's first cuts

    My TravelCNC reached it's most important milestone!

    The mobile CNC workshop in a custom made flightcase now has completely new electronics and made it's first cuts using it.
    It's now a usable, mobile 4 axis CNC milling machine.
    ...soon it will also be 3D printing and vector cutting.

    TODO:
    • add Basotect sound proofing
    • connect the USB control board to the spindle controller (speed in software)
    • add table legs to the top panel to use it as a collapsable work table
    • test 3D printing (ThingOMatic already disassembled, should work)
    • Replace 10A power socket with 16A version
    • add IP64 power sockets (you always need power socket in a workshop)
    • add mounting for vector knife (like drag-knife but cutting real 90° angles)




    2013-09-11

    The last honours for my Thing-o-Matic

    Looking at this blog, it must feel like I'm not doing nothing at the moment.
    This is far from the truth. Since I tried to keep things focused and have just one blog-post per project with all the infos one would need to replicate my work.

    Problem is: Where does one project and the next begin.

    Yesterday I prepared the new electronics for my TravelCNC.
    Today I gave my untrusty ThingOMatic the last honours and dismantled it.
    I'll keep the main boards, the extruder controller and the extruder stepper driver.
    However the mechanics will be that of my TravelCNC.
    Mach3 will control the CNC's motion and also give STEP+DIR pulses to the extruder stepper driver.
    The external display and keypad will help me set just the temperature while Mach3 executes the g-code. (With the extruder=E axis renamed to A.)

    One thing I noticed was that the GND cable of the extruder heater had molten it's mounting port.
    Since the extruder never had any issues with heating up or keeping hot, this doesn't seem to have had any impace. The cable never moved after all.


    Excuse the pool photos as  I didn't bring any of my cameras to this location.


    2013-07-04

    Travel CNC/3d printer/vector cutter combination


    There are people who have a travel toothbrush.
    There are people who have a travel hair dryer.
    For years I had a travel 3d printer.
    So why can't I have a travel CNC? ;)
    So why can't we have CNC mill, 4th axis, 3d printer, vector knife and resin casting and a work table in a single, mobile, quiet, clean tool?

    Here's the plan:
    1. disassembly my old, unreliable Thing-o-Matic to reuse the (non-original) toolhead and extruder controller.
    2. mount it onto a not-too-small (400x300), very quitet, 4 axis CNC milling machine
    3. make sure I can swap between CNC spindle, 3d printer and mounting the 4th axis to orient a vector knife
    4. put everything into a custom made stage box including locks, cooling-grills and properly sunk cable holes and a low enough side wall to reach the part you're working on easily
    5. sound proof the box
    6. Fit drawers for small parts, legs to make the box-lit a table, light and enough power sockets.
    7. win!
    Sounds easy enough, doesn't it?
    I have the CNC right here (awaiting a conversion to USB while converting my large CNC machine from USB to Ethernet and from 4 to 5/6 axis), ordered foam and box and am 3D printing the adapter to use the 3D printing head and all other alternative Makerbox heads I have.

    THIS BLOG POSTING GETS UPDATED REGULARLY AS THE PROJECT CONTINUES.

    Updates:
    2014-04-13
     Prepared a metal XL timing belt pulley for the 4th axis to replace the 3d printed one.
    2014-01-25
      The portal height extension is coming along nicely. Will do the drilling and thread-cutting tomorrow.
      Then it should be done. Got mail from the customs office. Maybe one of these packages are the replacement drivers. With the help of my new Makibox I can make the missing parts for 3D printing and vector cutting.
    2014-01-12
      Most of the metal-milling done to raise the portal and Z-axis by 100mm to increase the maximum diameter of parts on the 4th axis.
     Spacers for 4th axis and tailstock have been made out of wood during 30C3 to demonstrate the CNC.
    2013-12-30
      2 more stepper drivers blown during 30C3. Dealer "Thomas Wu" confesses they are only good for 45V, not the advertised 50V. (I'm using 48V)
    2013-11-20
      Tried to attach the foldable table legs and found that I made a mistake.

    2013-11-13
      I finished the sound proofing and the electrical wiring.
      All 4 axis are working again (replacement arrived).
      Waiting for some small parts to install tool height probe and E-Stop.
      Work on integrating 3d printing can resume now.

    2013-10-27
      Made molds and tried to cast my own sound proofing anchor fittings but they didn't dry in time for my weekly return from the home workshop to the city I work during the week.
      Prepared foldable table legs to make the upper part of the case into a table.
      Prepared fittings to slide the electronics panel in and out for service.
      Packed the tools needed to improve the 10A power supply cabling to 16A. (just to be way on the safe side.)
      Still waiting for my replacement Y-axis stepper driver. (3D printing and vector cutting on hold due to that.)

    2013-10-24
    Found that soundproofing needs a lot of improvement.
    Tried to upgrade to a 16A power plug...to find that the hole for the plug is too small. :(


    2013-10-22
     Parts arrived to add the electric tool height probe.
     Tailstock of 4th axis has the correct height now.
     Broke my edge-finder while testing the 4th axis.
     Still waiting for the replacement Y stepper-driver. Limping around with the A axis driver driving Y .
     Ordered a tiny vacuum cleaner to modify. It's quite difficult to clean the inside of a stage box from the top. ;)

    2013-10-21
    Need to move the 4th axis 10mm higher to have space for the longnegh NEMA23 stepper.
    Milling the required spacer to have the tailstock of the 4th axis at the same height as the collet.
     Parts arrived toupgrade from a 10A to a 16A power plug and cable and to add a power socket for manual power tools or laptop.

    2013-09-25
      Dry run of the Mach3 cncPrinter3D plugin failed but Slicr worked fine with Mach3.
      Extruder-Stepper not yet connected to receive STEP+DIR from CNC board in parallel with 4th axis
      Y-axis stepper driver went up in smokeFirst real milling using the A driver for the Y stepper.
      NO LOST STEPS ANYMORE!!!

    2013-09-24 
     First test cuts in cardboard.

    2013-09-23  mounted CNC into the flight case and mounted the wooden board with the new electronics.

    2013-09-22
      230V wiring of new electronics finished.

    2013-09-19
      cables to finish the 230V wiring arrived.

    2013-09-18
      All 4 axis working.

    2013-09-16
      new electronics working on 1 axis. Some trouble with the X driver.

    2013-09-15
      tested new Ethernet control board on large CNC, not that it's USB control board is in the TravelCNC

    2013-09-09
      preparing the new electronics. Mounting control board, power supply, ... to a new wooden board that will act as a separator inside the flight case.

    2013-09-02
      testing one of the new stepper drivers.

    2013-08-20
      vacation

    2013-08-08
      48V power supply finally arrived

    2013-08-05
      Added a ramp to load/unload it from the car.
      Will get the new 48V 400W power supply from the post office tomorrow.
      Then I can test if the new stepper drivers can drive these steppers and the USB board works.
      (no driver for Y+Z yet, only X arrived).

    2013-08-01
     I'm at OHM2013 (Village "Sandbox" of CCCfr). The case is finished. I can control the CNC3040 using the control box of the USB6040 and my USB-controller. Still have to wait for 1 power supply and 2 stepper-drivers to arrive before I can finish the control box for the 3040.

    2013-08-01
      wheels mounted (before leaving for OHM2013)

    2013-07-31
      presenting the CNC at OHM2013 (CCCfr Village)

    2013-07-23
     Got myself a cheap Dremel 4000 to drill.
     Casebuilder.com did NOT include the required drill bits as promised. A 6mm one to mount the wheels is missing and I dont' have one at hand.
     They also included both face plates for the cooling fans but only one side of the case has the hole to mount it.
     All the locks and half the face-plates have pre-drilled holes. But the other half of the faceplates has not and while at it they could have CNC drilled the holes for the rivets too in the same run.
     (They are pre-drilled in the aluminum but not the wood).

    2013-07-23
      need a faster drill, so the wood doesn't spliter. Time for OHM2013 is running out.

    2013-07-22
      got the missing drill to assemble the case. Also brought the blue control box of my YOOCNC6040 over to see if new electronics really take care of the lost steps.

    2013-07-16
      case arrived

    2013-07-11
     PROBLEM! T-slots on the CNC3040 are some odd, non-standard size.
     planned test with Ethernet/USB instead of LPT postponed.
     Basotect acoustic foam arrived.
     Stage box was shipped
     fastener material arrived
     First milling tests
     Using the supplied LPT board the 3040 looses steps in Y and Z.


    2013-07-10
     Jogging 4th axis tested and still not working now. LED doesnt glow.

    2013-07-09
     CNC working on LPT except I can't jog the 4th axis.
     PCB for convertion to Ethernet/USB arrived.
     Beefed up 4th axis tested (on CNC6040). Holding force fine now. (on Y-stepper channel)
     Waiting for the Case.

    2013-07-08
     First 3D printing test failed.
     Metal plate on Makerbot hot-end too large.
     3D printing postponed.





    2013-06-30

    Chinese 25mm f1.4 and 35mm f1.7 CCTV Lenses für Micro Four Thirds



      I found these 2 chinese lenses for $18 and $38 and wanted to give them a try.


      • C-Mount 50mm f1.4 covering a 2/3" sensor
      • C-Mount 35mm f1.7 covering a 2/3" sensor
      I'm trying to evaliate their usefulness for FullHD video recording and for 5MPx photography.
      Since they are f1.4 and f1.7, I'm comparing them to a completely unfair competition of modern high end lenses with similar apertures.



      • Panasonic/Leica 25mm f1.4
      • Voightländer 25mm f0.95
      • Voightländer 17.5mm f0.95
      My camera is a Panasonic GH2 (with hacked firmware but that doesn't change the results here).
      EX-Tele mod is not used. Aspect ratio is 16:9 . Thus the crop factor is 1.86 since it's a multi-aspect sensor and no regular  4/3 sensor.

      A normal 4/3 sensor would have 2.0 and a 16mm Blackmagic Pocket Cinema Camera 3.0 .
      These would have less of an issue with the blurry corners of these lenses made for 2/3" or 1"=3/3" sensors. We are using these lenses way outside their intended sensor size.
      • All Photos (Including other apertures. Scaled to FullHD due to Picasa quota.)

      Here are the references:
      Leica 25mm Voightländer 25mm Voightländer 17.5mm
      (All wide open at the fastest aperture)

      Panasonic/Leica 25mm f1.4

      Voightländer 25mm f0.95

      Voightländer 17.5mm f095

      Now the C-Mount 50mm wide open and fully closed.
      I know they are hard to compare since the focal lengthes put the C-Mount lenses at a disadvantage.
      On the other hand trees are known to have tons of detail at any field of view.
      C-Mount 25mm f1.4Add caption

      C-Mount 25mm f1.4 at >f10
      These photos have been scaled down to 1920x1080 FullHD since the lenses are completely unusable beyond that.
      Both lenses are extremely prone to stray light. So don't judge the contrast using these images.
      They must be used with a lens hood (no thread, must be improvised) or french flags.
      The center of the f1.4 image is somewhat usable if moving. Everything outside the center is so blurred that this only works out when it's
      • either a dream sequence or 
      • something in the center of the frame is to be shown in a very shallow depth of field anyway or
      • it's an action cam that's only visible for a short period with the viewer distracted by the action and the lens is at risk of being destroyed.
      Stopped down it gets somewhat better but why would you use this lens stopped down except to get lots of motion blur in an action sequence.

      Now the 35mm f1.7 C-Mount:

      C-Mount 35mm f1.7

       
      C-Mount 35mm f1.7 at >f10

      Same issues. Just another focal distance.
      These may yield slightly better results on a Blackmagic Pocket Cinema Camera due to the higher crop factor yet they still will be very blury outside the center.

      Both are nice toys where it's not important if they break or not since they cost next to nothing.
      For a few Euro extra you'll get some old Canon FD glass that may have purple fringing and just match the sharpness of these in the center but keep that sharpness into the edges.