Wednesday 16 November 2016

Saturday 17 September 2016

Sunday 31 July 2016

Belt driven cnc - aluminum cutting - 1mm cutter

Today i have first cut on my new CNC machine.
Belt driven.
Cutter - 1mm diameter
Speed 1mm/sec
Firmware - Marlin

Sunday 17 July 2016

PCB milling on marlin (with modified pcb2gcode)

Hi
I just done with pipeline setup for pcb milling.

My cnc based on Ramps 1.4 and Marlin software.

Today i tried to mill pcb.

PCB was created in KiCad (macos version very buggy by the way).
GCode was produced by pcb2gcode.

The only one problem i got with pcb2gcode is a Marlin firmware incompatible gcode.
I did a few changes in pcb2gcode - this is my fork - https://github.com/pavlog/pcb2gcode

Details:
basic pcb2gcode gcodes:
G01 Z-0.05000
G04 P0 ( dwell for no time -- G64 should not smooth over this point 

F600.00000
X8.35500 Y35.63460

Marlin does not understood naked F X Y commands, they are shouldbe with G01 commands like lines bellow.

G01 Z-0.05000
G04 P0 ( dwell for no time -- G64 should not smooth over this point )
G01 F600.00000
G01 X8.35500 Y35.63460
 By the way pcb2gcode successfully compiled for OSX using Macports.



 

Saturday 21 May 2016

DeltaXY mechanics - printed prototype

DeltaXY 3d printer

Hi everyone
I started working on DeltaXY Kinematic

Idea descriped on video bellow


Web Visiaization - https://jsfiddle.net/1nhsvsvu
My targets:
  • 100x100x100mm build area with smallest possible box (approx 140x200x150mm)
  • Closed build area
  • Fast
  • Cheap
Z-Axis seems to be moved platform.

Thanks for your feedback...any suggestions, critique and discussion is appreciated.
P.S. I have printed a few parts already.

Sunday 15 May 2016

New 3D printer started

I've started new 3D printer.
New non standard mechanics.
First printed parts on photos bellow.

Sunday 1 May 2016

Scara V3 printing

 
Scara V3 Printing gear for geared extruder. Seems like my old Delta printer retires.

Sunday 20 March 2016

Offtopic: Appium - OpenGL based app automation testing

AWS Device Farm and Appium

A few days ago i checked "unread" emails in my account. One of them was from Amazon AWS about their AWS Device Farm.
I checked it on one my mobile application, everything was good but only "Fuzzy testing" option was suitable for me.
I saw "Appium python" option and  decided to do some smart tests for my application.
The biggest problem is a testing UI for OpenGL application, because OpenGL application uses one GLView, UI in games rendered by OpenGL and Appium does't see app UI hierarchy and controls - only one root view.
As a first steps i used tap events to simulate pushing of OpenGL drawn buttons. 
This technique was good for devices where width and height is known and buttons always in the same places, but may fail in other cases (like other device orientation or width/height aspect is different). Also there is no feedback. Test does not have ways to determine is button was pressed or not.

Example to simulate button pushing:
window_size = self.driver.get_window_size()
# tap ok button  
positions = []positions.append((window_size['width']/2, window_size['height']*0.7))self.driver.tap(positions)

NOTE: AWS Device Farm and Appuim examples is available here
NOTE2: Good start point for Appium and AWS  is available here 

The feedback

Seems like i need some ways to organize feedback between app and Appium
I had a few ideas: 
  1. Hard and long - Instantiate simple http server on app side and organize network pipe between app and python test script. i.e. my python test script recieves data about controls hierarchy (of cause you opengl app should send UI layout and controls to this pipe)
  2. Fast but hacky variant - use something simpler - i choosed this one

 Feedback (Hacky)

I used special key codes to send event to my app to activate testing mode (i used key press event with almost impossible keycodes for android app)
def activeTestMode(self):
   # activate test mode   self.driver.press_keycode(152);
 In my app key code 152 is a signal to activate testing mode, when app receive this signal it just adds TextView on top left with "TestActivated" text


        if ((event.getKeyCode()==152) && (event.getAction() == KeyEvent.ACTION_DOWN))
        {
                appiumPipe = new TextView(this);
                appiumPipe.setId(123456);
                appiumPipe.setTag("AppiumPipe");
                appiumPipe.setText("TestActivated");
                appiumPipe.setBackgroundColor(Color.RED);
                appiumPipe.setSingleLine(true);

                FrameLayout.LayoutParams params = new FrameLayout.LayoutParams(
                        FrameLayout.LayoutParams.MATCH_PARENT,
                        FrameLayout.LayoutParams.WRAP_CONTENT, Gravity.TOP);
                params.setMargins(0, 0, 0, 0);

                appiumPipe.setLayoutParams(params);
                frame.addView(appiumPipe);
                return true;
      }
Next i used Apium api to find this control:
els = self.driver.find_elements_by_class_name('android.widget.TextView') # find_elements_by_xpath('//android.widget.TextView[*]')print els
# find textviewfor element in els:
   if element.text=="TestActivated":
      self.AppiumPipe = element
      break
 When control found the control text used as a pipe between app and my Appium python script.
Next - the other key code 153 used to send signal  to my app to update this control with my gui hierarchy in json format.

def updateTestInfo(self):
   self.driver.press_keycode(153);
   time.sleep(1)

   #print "-------------------"   #print self.AppiumPipe.text   #print "-------------------"
   #print AppiumPipe.name   self.data = json.loads(self.AppiumPipe.text)
   #pprint(self.data)
 
        else if ((event.getKeyCode()==153) && (event.getAction() == KeyEvent.ACTION_DOWN))
        {
                String res = NativeMethods.executeCommand("APPIUM:GetJSON", null);
                appiumPipe.setText(res);
                return true;
        }
String res = NativeMethods.executeCommand("APPIUM:GetJSON", null); is a code in my app returns gson with my internal opengl controls

After parsing json from control text i know elements and places of visible controls in my GUI

def controlCenterByPath(self,json,path):
   pCur = self.controlByPath(json,path);
   self.assertIsNotNone(pCur)
   return (pCur['x']+pCur['w']/2,pCur['y']+pCur['h']/2);

def tapControlByPath(self,json,path):
   pos = self.controlCenterByPath(json,path)
   # set up array of two coordinates   positions = []
   positions.append(pos)
   self.driver.tap(positions)

Simulation tap by Control name

self.updateTestInfo() # call this to update UI gson
self.tapControlByPath(self.data["TopLevel"][0],"DialogPanel.OKButton")

Validation


self.updateTestInfo()
time.sleep(1)
nodialog = self.controlByPath(self.data["TopLevel"][0],"DialogPanel")
self.assertIsNone(nodialog,"Reward must be closed")
 

Sunday 17 January 2016

Scara based 3D printer V3 details

Scara based 3D printer V3

Details:
  • 100mm arms, designed to cover almost all mk2b heated bed, 
  • 1/4 reduction ratio (gt2-16 teeth to 64 teeth)
  • 608 bearings used for center axis
  • 624 bearings for other.




Saturday 9 January 2016

Scara 3D printer v2 - fail

Short review - fail.

Aluminum tubes (od-8, Id-6) too weak, on a 30 cm distance twists for a 0.5 degrees along 30cm. 5mm threaded rod have the same problem.
Because of issues above printing results does not match target quality.

But, v3 is started.

My v3 ideas:
1) classic arm scheme
2) platform is fixed, printing block movable
3) smaller footprint -50x150x20mm
4) ability to convert to robot arm manipulator