Posts

Showing posts from April, 2007

Moving code from ESP8266 to ESP32

Image
A while ago I made a mashup of Dan Royer's code CNC 2 Axis Demo with my own code for trapezoidal motion stepper and servo control for ESP8266.

I assumed porting the code to the ESP32 would be trivial, and that was true for the most part: changes like library name being Wifi.h instead of Wifi8266.h were not a problem. UDP now does not like multicharacter writes but you can use print instead. So far so good.

However, when it came to the interrupt code I was stuck with the stepper interrupt causing an exception sometimes. And to make things weirder, the servo interrupt worked flawlessly (both of them had the IRAM_ATTR directive if you ask me).

Going little by little, I could narrow down the culprit to a floating point operation during the interrupt, that would cause problems sometimes but not always. Browsing around I found this post. Where the solution was simple: do not use floats within the interrupt routines but doubles. The reason was the float calculation would be performed by…

Graphics fun

Image
I was watching some paintings by Chuck Close and I thought of doing something in that direction but, of course, letting the computer do the hard work. I'm not yet finished as my initial goal was to create a GIMP plug-in (as Photoshop is not my thing), but I started using Perl and the GD library to get results like the one in the photo.
If you are interested in the perl code just drop me a line, it can work with any photo file (once you convert it to a GIF file). If you are familiar with GIMP plug-in creation you might want to help out finishing the work!

Time to switch away from Microsoft?

I have been testing Office 2007 and its new user interface. I did like it. But at the same time I did have some trouble finding some options (like the Save As ... --a hint: press the circle on the top left--) but the general feeling was that it should be easy to get use to it. However, another idea came to my mind: Over the years I have heard people from different companies saying that while OpenOffice was kind of ok they did not want to incur on the extra cost of re-train employees to learn how to use OpenOffice. The bottom-line now is that I find much easier to switch from previous versions of Microsoft Office to OpenOffice than to Office 2007. And I have not yet mentioned that file formats have changed too for Office 2007!!

This fact considered alone might be addressed by not switching to Office 2007 anytime soon. This is what all the companies I know are doing. But the second most amazing thing I can see happening is that no companies are switching to the much-hyped and secured Win…

Better video

Image
When I built the vertical plotter I mentioned one week ago I realised the video I was posting was not very good. I have received no complains but as I was painting something else over the weekend I decided to shoot it better and to fast forward a bit so as not to bore you to death. This is the result:


And before you ask me, this is the photo it is coming from:

Windows Log Files

Image
Today I needed to dig on a client's set of log files. I'm happy with text-based log files, but this time most of the research has to be done on Windows 2003 Server Event Logs. The problem is that in order to view this files you have to be running Windows 2003 Server and you have to use the Event Viewer program (or so I thought).

After having some trouble because I was not aware that Event Viewer is not happy when your files are read-only (as when you are handed over a copy on a CD-ROM) I decided it has to be a better way. Unfortunately, Event Viewer error message just said "wrong parameter" which is not telling you much about the cause of the problem.

A bit of Google and I discovered a software gem called LogParser, which can parse most of the different log files Microsoft OSs and applications create and, to ice the cake you can present your queries using SQL sentences on the command line. Many input and output formats are supported and it can also deal with your Apach…

New article published

April 2007 CircuitCellar #201 featuresanarticleaboutmyresearchontheinnerworkofECP bus that has beenusedinADEMCOalarmsformanyyears.

Note: Itisnotavailablefor general downloadbutforsubscribersonly.

Yet another shameless copy

Once I get one project running I tend to focus not on creating a polished version of it but on the next project to do. This time I am planning to build a 3D scanner for body parts (i.e. hands, arms, head) so I can create a polygonal version of them like an sculpture. The good news is that it's been done many times before: like this one, or this other. Some people even took the time to create an open source project to develop the software for such a homemade 3D scanner.

As I am yet in the early stage of the project I can only tell you that a line laser and a webcam (or photo or camcorder) are needed. The line laser is a laser that creates a line shape instead of a single spot. The cheapest alternative if you do not have one is to buy one of these straight line levels. Alternatively you can create a line laser from a laser pointer by inserting a cylindrical lens on the laser beam (any solid cylinder shape of plastic or glass can work here).

Once you have the laser line you also need …