I found I kept making and drawing tile sets for little games I wanted to make and I found it time consuming. some engines require a bit of padding around each tile so that when the drawing is scaled, the next pixel isn’t shown from an adjacent tile.
I quickly wrote it in freebasic in under an hour, there’s an EXE in there too if you don’t want to use freebasic or look at the source. very little to it and everything is straightforward. The program will generate a blank tileset with both borders and internal padding indicators. I may write a program sometime that will automatically pad the tiles as needed from an existing set.
In my time making things for my YouTube channel, I’ve made a little series of videos detailing my creation of a crummy pong game. Fact of the matter is that I haven’t done some serious programming in some time so I needed to wet my whistle so to speak. You can play this game here. Quickie Pong!
So, for anyone who wants to view them, here are the videos for anyone’s perusal. Oct 1, 2016 is when the 3rd video is published so, if anyone cares, that’s when it is available.
Anyways, hopefully somebody enjoyed that. If not, you;re welcome to like and subscribe anyways!!! Again, go to my channel 🙂
It has been a long time since I wrote a game. This one just took me by surprise as I was playing Flappy Birds for the first time. Having heard that the author pulled it. I wanted to make my own version but different.
Pulling from Super Mario Bros. and Flappy, I came up with this. I started writing it at work today and am now finishing up the levels. Hell, I even made a little title graphic.
Well, it took me about a day to write the game but the levels are another thing. I will update the game as I finish the levels and hopefully someone, somewhere enjoys this game.
Well, it’s coming along with some speed. I am now going to build the final version complete with internal battery charging, better logic and a severe reduction in mass. Hopefully this will go down well with the customer.
Anyways, this post was for posterity. As always I hope it turns out well. 🙂
It’s been a while since I’ve posted and that’s primarily because I’ve been working on a project. I have to keep some of the details to myself but I will show some pictures of the prototype that has taken me a couple of weeks to design and build.
The device uses the AT715 from Mitutoyo and what an interesting device it is. With a resolution of .0005mm and an RS485 interface, it is an ideal device for measurement and for use on machines. The device, which uses magnetic induction, uses 30ma whereas a lot of other glass scales use up to 250ma @ 5v. This is a pretty cool device.
Well, I can’t get into a great deal of detail because the product I have in mind may compete with other gaging companies like Gagemaker with a universal, handheld, high precision, digital gage that has active, rugged and dynamic probes. The images shown are that of a rough prototype, I’m not normally secretive but once one is built in a few weeks I can post some images of the more refined version.
I’ve been playing around with Game Maker HTML5. Pretty neat I must say. This game is pretty simple and revolves around multiple balls flying along the screen and you protecting your net. The grey, recently created balls do not count as a score so you can ignore them. Nothing special really.
Just wrote a little FreeBASIC program for calculating the length of the day and the difference from each. Just enter your latitude and it’ll output a text file for the length of the day and difference from the previous day.
Anyways, it’s not well programmed or anything but the function could be useful for somebody out there. Who knows
So, even though I’ve built a wide variety of crap over the last few years, all of them with varying utility, I’ve decided to build a quick robot. With oodles of free time and the feeling of having to go back to work on the horizon after what feels like an eternity of holiday (1 week) I quickly grabbed a bunch of stuff I had sitting around and put this guy together with all the grace of a kindergarten macaroni art sculpture.
Based off of an Arduino Nano, this guy works just fine. I don’t like using Arduinos for the following reasons.
Perceived lack of control of what’s going on inside
Feels like cheating since it’s so easy
Arduino UI is kind of shitty, especially for larger source files.
When dealing with AI routines, making it difficult to use multiple files is a minus
Anyways, i plugged ahead and quickly pounded this out with the following IO
Input – The only one, the Echo pin on the ultrasonic sensor
Output – Trigger on ultrasonic sensor
4 Digital output – for controlling direction on SN754410 Quad half h-bridge driver. These go to two gear motors which are attached directly to wheels
1 PWM out for duty on motors
1 attached servo out of the servo to turn the sensor
Most everything worked out swimmingly until I fucked around with some wiring and produced a short. I hooked the robot on to the USB supply on my computer, I noticed after a few second that the power to the unit wasn’t running… hmmm POOF! Well, as it turned out, there was a problem with the wiring to the ultrasonic dealy and it blew what I beleive was a zener diode
I wasn’t able to figure out exactly what it was, I suspect that it is a zener diode that selects between main power and USB since it is on the output of the VReg. I could be wrong. Since I didn’t have any more Arduino Nano’s I simply tried to fix it and soldered a wire across the offending gap. The device seems to work fine…? Anyways, if anyone know what that part was on the Arduino Nano v3.0, I’d like to know ’cause I couldn’t find the 3.0 Schematics and the design has moved those parts around.
Anyways, The robot moves around based on a very simple algorithm.
Scan from 40Deg Right to 40 Deg Left in 10 deg increments
return appropriate movement from a function that analyses it
execute proper movement (Forward, Backward, Right, Left, Hard Right and Hard Left)
It seemed to work reasonably well. I’d like to build a more sturdy version for shits and giggles so that I can play with the algorithms. I’m probably gonna build one with a PIC18F2685 instead of an Arduino. Also, instead of a single sensor, I will use IR proximity sensors to detect low lying objects. Moving the sensor with the Servo make the robot seem more intelligent than it actually is like it’s ‘looking around’. I quite like that. 🙂
Anyways, it’s my first post of the year, considering it’s January 1st and 3:52 am as I write this. maybe I should go to bed. Here’s a video of it getting around.
Ok, well, the year is coming to an end and I’ve seen a number of neat devices out there but here are some that I own. The next year coming up is a going to be an interesting year methinks especially since there’s gonna be some big changes in my life, not to mention the fact that I’ve quit smoking for some time now.
Anyways, here they are:
This nifty little device is the Arduino NANO. Now, me being me I believe that the arduino’s are something akin to cheating since you don’t need a programmer, it runs right off USB and communicated directly with the computer. The small size of this device and the ease of use make it truly a neat device. Call me lewis ’cause I am starting to like the arduinos. They sell for as little as $14 on EBay (they are probably knockoff but work fine) and are strangely useful for bashing out simple stuff.
Mini PIR Unit
This little guy can detect motion (heat difference) up to 5M away. it only draws .15mA and costs only about $4 on Ebay. The interface is simple with two trim pots, one to set the sensitivity and one to set how long the signal stays high when triggered. I bought a whole bunch of these for a project I never finished (A distributed monitoring system) and I might make something cool out of them.
This little guy seems to work really well. Based off the nRF24L01 chip, this transceiver will draw about 15mA at continuous load. If you’re using it intermittently, it’ll run at about 2mA. Alos, it was really hard to get an image of the pinout for this device since the seller kept saying they’d give it to me and never did. Here’s an image of the pinout.
You can get these devices for about $4-5 each. A real steal.
CP2102 USB to Serial out
These guys are useful because you can plug a test device directly on to the usb port and not need a max232 or equivalent. It features a 3.3 and 5v port and works like a damn. Concievably you could use this with an intermediary to provide the SPI interface to the 2.4GHz Transceiver and use it to provide communication to other transceivers to the computer.
This is the ultrasonic transducer. I was playing with it last night and it works really well. It measures anywhere from about 1 inch to 16 feet or so. Simply provide a short 10 to 100 us pulse to ‘trig’ and measure how long the ‘echo’ pin remains high. the ‘echo’ pin will go high after a delay once the trigger pin has been pulsed. I was able to get pretty good accuracy once I calibrated it and with some averaging routines I was abble to get resolutions of about .01″. Surely it wasn’t THAT accurate but it was close. These again were only like $6 each. It should be said, that with full measuring duty this device draws about 15mA.
Anyways, that’s what I’ve been playing with. Hopefully other people may purchase these little trinkets and have fun. EBay sure is an awesome place for the hobbyist like myself for weird knick-knacks!
Well, since I posted a bit of stuff yesterday I’m gonna post a couple of other things I’ve been playing with. Since I finally have a day off. may as well.
The FPS I’m making
I don’t know what I’m gonna call it, I don’t even like FPS’s anymore. I dunno. Anyways, heres a screenshot
Arduino and ChipKit
Like I mentioned yesterday, I’ve been playin with both the Arduino and ChipKit. Frankly, I need to get over my personal bias over these arduino based things. The way I feel about them is that it’s like cheating, where very little learning is required to make some sort of result.
I am however wrong. With the progress of technology we use technologies that are based off of previous technologies. Even using MCU’s would technically be cheating by my reckoning since we should be using a CPU and related chips. Then even deeper we should be using nothing but transistors in order to not cheat. So, by that reason, I am wrong. Using an arduino and premade shields shouldn’t reduce the feeling of accomplishment at all. Now that we don’t have to worry as much about hardware, application becomes top dog.
Anyways, Here are the Arduino and ChipKit
Now, as it might seem, the chipkit is quite a bit more advanced. It uses the same arduino software for compilation. It is also substantially faster. There was a comparison done, here on hackaday. It is a really neat device despite the fact that the software isn’t optimized.
The only problem though, as I have already mentioned is the voltage difference. So, it can be said that many shields would not be compatible with the chipkit. They do have similar layouts though.
A problem I did have with the chipkit was that the software wouldn’t write to the chip. apparently I had to download and burn the new bootloader to the MCU that was on board. lucky thing I have a pickit3 and was able to burn it, otherwise it would’ve been a brick. I think it’s odd that they didn’t test for that (apparently it was a certain batch of pic32 mcus that had a problem)
Something I do like about the chipkit is the extra IO and the fact that it uses a miniB plug rather than a massive printer usb plug.
At 4$ shipped per piece, these are wireless units. they have a variable frequency selectable by software and have a range of about 100m. I was going to make some of the centerpieces with them but since people take them home, it’d be pointless.
It’s been well over two months since I last posted. Frankly, not a lot has happened in the meantime anyways. Work is going well and life is pretty good. That said, I’ve begun to regain my inspiration for electronics again and I’ve been going hog wild building stuff in the evenings. Just some stuff to touch on I guess…
Well, again I have a secluded labratory in the shop I work at. It consists of 2 desks, two shelves and all of my equipment. It’s nice to hang around and listen to music and stuff while having access to all of the manufacturing facilities I could ask for!
Here’s a picture of my lab as I was setting it up.
It’s a real treat here and I’ve been sitting up here for many hours on my projects lately. Yay!
A veroboard planner PDF
Not really a project per say, however, somebody might want it. It’s for printed pcbs from PCBIran which have a ground loop on the outside and sets of rows and columns. Somebody may find it useful. I dunno.
The shop I’m at is investing in new technology (IE. CNC mill and CNC Ram EDM) and I figured it’d be neat to take an overview picture. Sure is crowded though. 🙂 The mill, as was stated earlier, is a Haas VF-5 with a 40 taper and the Machine is a large CHMER EDM, more on that thing later in the post
It’s actually much tidier now, this is when we were installing the EDM.
Rotary Table and CHMER EDM
I am developing a rotary table interface for the CHMER Ram EDM. The fools at CHMER decided that the machine requires NO extra M-codes for interfacing to external hardware… WHY!!!??!?
So now I have to monitor the outrush current of the pump, turn it on and off a prescribed number of times and then the rotary table can index. I’m still kind of in shock that nobody has ever presented CHMER with this problem. Weird!
The TI Launchpad
I have just ordered the TI launchpad for $4.60 or whatever it cost. TI is attempting to break into the hobbyist market something fierce. unfortunately, after looking at the development tools available, they are all way overpriced.
While they do provide a code-size limited version, which is useful for most things, I think people like to have unfettered access to their chips and what kind they use from a particular vendor. When the development tools that allow this are in the $500 range, that’s simply too much.
Perhaps there will be some good 3rd party support like Atmel and Microchip has and they can really take their MCU’s to the next level. It’d be very cool. 🙂
Well, there is probably still more to say after such a long hiatus but I can’t think of it now. I do have some other ideas banging around in my head like a new design of the coolant refractometer which won’t foul. A robot that is machined beautifully and function on sonar. And a new coolant nozzle design that will kick Spider Cool’s ass from here to main street (I’m actually pretty stoked about this one).
The company I work for has recently purchased a Haas VF-5 40 taper machine to augment the capabilities of the shop. Seeing as they didn’t have one before, this will greatly improve the capabilities of the shop.
The item of interest to me is the fact that it’s brand new and Haas has made a number of changes to their CNC mill line. Aside from their new higher contrast 2-tone paint job and sharper featured shrouding, here are some interesting changes that they’ve made. This may not be new to some people but if you haven’t used a haas made in the last 4 years or so, this may be of interest.
Nothing amazing about this control aside from the fact that the screen has a lot more info packed on the screen. Selecting one of the screen buttons toggles between the panels rather than actually displaying a different screen. None of the buttons have changed their functionality otherwise. I do find the screen switchovers to be a bit laggy and difficult to read at a distance but it is otherwise OK. Also Probong has a much more integrated setup than in previous versions whereby you can offset tooling from the tooling screen.
The Jog Pendant
Like the image says, the pendant now has an LCD screen. It also features two sets of dials and a toggle lever for axis slelection rather than the rotary switch allowing you to use it without looking too much at the labels.
The larger dial on the face is an analog dial that allows jogging at various speeds and goes about a quater turn left and right that springs back. the smaller one serves the original purpose of increment jogging. Increments are chosen on the screen rather than on a dial.
Also, things like current program, offsets, and various other minutia can be displayed.
There are is a problem though. That being the noticable lag from the pulse encoder to motion occuring on the machine. Often times when you want to move there is a considerable time difference from when you turn either the analog wheel or the pulse encoder. Also when you use the pulse encoder at a high rate, it skips many of the ticks or gets “jumpy”. the motion is not smooth.
Overall though the functionality is greatly enhanced.
The rest of the machine
Here are some of the other changes I’ve noticed.
Different Coolant arrangement
Different design on the programmable coolant
Side window locks
an additional set of shelves on the side with a light
Power saving settings
Different Shrouding and duo-tone paint.
Removal of coolant tray around table
Shrouding around chip spigot
Raised handlebars for moving coolant tray
There are probably more changes than are what is listed here. Here are some pictures of the machine