Tiny Computer with Printer port

More
14 Jul 2013 21:46 - 14 Jul 2013 21:47 #36640 by PCW
Thats probably the easiest solution

Power the proximity switch from 24V but use the output to pull the GPIO input to ground, That is, connect the switch output directly to the GPIO pin and use a pullup/load resistor connected to 5V instead of 24V.

There may possibly be problems with this method. The switch specs a 2.5V maximum voltage drop. This may mean that a low level output is not a good low for the TTL levels the the GPIO pin expects. So maybe the first step is to check what the switch output levels are in both states with a 5V pullup resistor.

Another option is to use a opto coupler circuit. This has the advantage of keeping the 24V far away from the fragile GPIO pins.

As far as inversion goes, that can be done in HAL, either by choosing
the correct true or inverted GPIO input pin if the driver supports this or using HALs 'not' component
Last edit: 14 Jul 2013 21:47 by PCW.

Please Log in or Create an account to join the conversation.

More
16 Oct 2013 19:04 #39957 by tkamsker
Hi
I have prepared 2a PCB which is dividing the voltage from 24v down to 5 v then uses an optcoupler to be able to selct if Pullop or down
So if there is interest i can publish the eagle files i have an PNP and NPN version ,.. I use it for spindle orientation

And here is a picture from my setup (for the endswitches i use the Functionality of my BENEZAN Triple Beast board )
thomas
Attachments:

Please Log in or Create an account to join the conversation.

More
10 Jan 2014 03:56 #42563 by bz01t4
Bought one of these last month, just getting around to trying to make it work. Went through the process of formatting the flash card (16G Monster CF, 500x, 1st part 7.25G ext2, 2nd part 7.25G fat32). Used puppy linux, GParted to partition and format. Formatted a 16G usb drive (as ext2) to store the compressed image, then uncompressed it. Then used the dd command as specified to get it to the CF card. No errors. Looked at the contents - it appears all the stuff is there. When I put the CF card in and boot, I get "operating system not found". I am clearly missing something but can't for the life of me figure it out. I write embedded SW for a living and know just enough to be dangerous in linux. Any hints out there?

Please Log in or Create an account to join the conversation.

More
10 Jan 2014 05:37 #42565 by ArcEye
Hi

At the most basic level check BIOS and see what it is trying to boot from (you will need a PS2 keyboard not a USB one as that is not active yet)

I am guessing you do not have a linux machine as your transfer method seems rather tortuous.

I am also curious about the missing 1GB in your CF card and whether the 1st partition starts where it should, or whether it are the result of the usual 1000 versus 1024 calculations.

regards

Please Log in or Create an account to join the conversation.

More
10 Jan 2014 06:27 #42566 by bz01t4
Thanks for the quick reply! Tried to boot the CF from a known good PC and got the same result - so I'm pretty sure the little yellow box is trying to boot from the CF as well. No, I don't have a dedicated linux machine but I've never had trouble with puppy (also used a live linuxcnc cd in the past in a PC that sounds like a B-52 under full throttle- the reason I bought the little yellow box in the first place). And yes, the missing 1G is due to the manufacturer's definition of what 8G means. As far as where it's located on Partition 1, according to GParted, there is "0" free space preceding the partition. I'm not sure how boot sectors work in linux (or how grub or lilo work). But this is where the trouble seems to be. Also, I noted there is a way to manually fool with the boot flag with GParted (it is currently set, 1). I don't know if the boot flag implies boot code in a boot sector or not. Or whether the boot flag is just a flag. Is there anything magic about the 8G size you suggested using? Could I format the entire CF card as ext2 and just have 1 partition? I'd be happy to provide screen shots, run any diag or log on the CF card to gain any useful troubleshooting info. Appreciate the help and am open to suggestions...

Please Log in or Create an account to join the conversation.

More
10 Jan 2014 15:13 - 11 Jan 2014 01:08 #42573 by ArcEye
Hi

Linux doesn't take any notice of boot flags really, you can boot from any partition, anywhere on a HDD, unlike windoze, which still seems stuck on 1st partition, 1st drive.

The need to boot the NCBOX from partition 1 is from the BIOS which is fairly limited.

The image will write the boot sector, FAT etc because it is a complete disk image.

When did you download the image? I changed servers recently, it is just possible that it got corrupted in the move, although just as possible it was in the download or transfer.

I would wipe the card again, repartition and format and repeat. If you have time to download the image again first, that should eliminate things at your end and if still no joy I will try uploading a new copy to the server

regards

EDIT

The MD5sum for the image is 6cb6414eb2578fa40439ef38eea0c95e

If that does not match, let me know and I will check the one on the server this evening

If it does, it is on your end, suggest re-download, and rewrite to CF
(preferably download with wget from a Linux install or live CD, because the server is linux and windoze often screws up more than just file permissions etc)
Last edit: 11 Jan 2014 01:08 by ArcEye.

Please Log in or Create an account to join the conversation.

More
11 Jan 2014 01:03 #42582 by ArcEye
Hi

I have now downloaded the image from the site and done md5sum

Done the same on the site mirror it was uploaded from and on the backed up original they are both copies of

They all have the same md5sum 6cb6414eb2578fa40439ef38eea0c95e

So if yours does not match, download again

If it does then look at re-partitioning, formating and writing the image.

No-one else has contacted to report any problem and I am getting half a dozen downloads a week via the DMP and Roboboard sites, so assume something went wrong at your end

regards

Please Log in or Create an account to join the conversation.

More
11 Jan 2014 03:10 #42585 by bz01t4
ArcEye -thanks for your efforts -really appreciate it. I have loaded multiple times both from your server and the mirror. Should have mentioned that. So yes, the problem definitely lies between the monitor and the chair. I am making progress, however. Used a Grub bootloader config app in puppy to install loader (used Root, Install to superblock of Linux partition) on CF card. Was able to boot into Grub. But currently unsure/unable to point Grub to where to start. I'm assuming it has to do with the menu.lst file? It's weird - clearly the PC knows what disk it booted off of since it booted, but somehow at a higher abstraction level I need to specify as part of the config where this disk is in terms of /dev/hdxxx or /mnt/hdxxx in menu.lst. This is currently where I have my opportunities to learn. The recent fooling around I did with Grub may have erased the original menu.lst or other config file I'm not aware of. Anyway, I'll plow on and keep the thread updated so in the event someone else runs into something like this there is some info available.

Cheers -

Please Log in or Create an account to join the conversation.

More
11 Jan 2014 04:05 #42587 by bz01t4
Finally got ubuntu boot screen. Hopefully now a slam dunk.

Recap of issue/steps to resolve:

01. Used win machine booted w/ usb puppy linux to prepare CF card
02. Prepared 16G USB drive as ext2 using GParted for scratch memory
03. Plugged in 16G 500x Monster CF card in USB CF card reader, plugged into USB
04. Used GParted to partition/format CF to half ext2 and half fat32
05. Copied compressed img file to 16G USB drive
06. Uncompressed img file using bunzip2
07. Used dd command to install image to CF card, partition 1
08. Put CF card into little yellow box PC, booted and got "No OS" message
09. Reconnected CF card to win machine in step 1, ran Grub bootloader config app
10. Installed bootloader to superblock of linux partion on CF card
11. Copied menu.lst.old (renamed from above step) over menu.lst
12. Put CF card into little yellow box, rebooted and got some joy

A few things I'm not sure about still - during ubuntu boot there were some issues -
CPU: vendor_id 'Vortex86 SoC' unknown, using generic init.
CPU: Your system may be unstable
...
* Setting kernel variables...
error: "kernel.maps_protect" is an unknown key [fail]
...
a bunch of
chown: failed to get attributes of /var/log/dmesg
chown: cannot access '/varlog/mail.warn': No such file or directory
chown: cannot access 'var/log/user.log': No such file or directory
[12 more chown issues]
syslogd: /var/log/news/news.crlt: No such file or directory
syslogd: /var/log/news/news.err: No such file or directory
syslogd: /var/log/news/news.notice: No such file or directory

* Doing Wacom setup...
cat */ld: No such file or directory

Are these just linux runny nose issues due to the specific rti/linux cnc build?

Thanks!

Please Log in or Create an account to join the conversation.

More
11 Jan 2014 15:12 - 11 Jan 2014 15:23 #42610 by ArcEye

Finally got ubuntu boot screen. Hopefully now a slam dunk.


Glad you sorted it, although don't understand why reinstalling the boot loader was required.

I did wonder if these CF cards had hidden sectors at the beginning like the Sandisk windoze s**t usb sticks, that you have to wipe with a special program before you can boot anything from them.
The only reports I found on them were that some cameras could not read them properly.

A few things I'm not sure about still - during ubuntu boot there were some issues -
CPU: vendor_id 'Vortex86 SoC' unknown, using generic init.
CPU: Your system may be unstable


You will get that every time, the processor is a specialised one and either not recognised or not signed properly.

* Setting kernel variables...
error: "kernel.maps_protect" is an unknown key [fail]
...
a bunch of
chown: failed to get attributes of /var/log/dmesg
chown: cannot access '/varlog/mail.warn': No such file or directory
chown: cannot access 'var/log/user.log': No such file or directory
[12 more chown issues]
syslogd: /var/log/news/news.crlt: No such file or directory
syslogd: /var/log/news/news.err: No such file or directory
syslogd: /var/log/news/news.notice: No such file or directory


Ditto, albeit some of the logs are probably ones that haven't been created yet so will drop off.

If you change the boot line in menu.lst from ending in ro to ro splash quiet, you will live in the same fools paradise as 99.9% of users and never see the messages B)

* Doing Wacom setup...
cat */ld: No such file or directory


I suspect the error you got might actually be cat: /etc/ld.so.conf.d/*.conf: No such file or directory because that seems to arise quite often when intalling a wacom tablet
when permissions aren't set properly. You will have to search on your particular tablet and Ubuntu, should find the answer

regards
Last edit: 11 Jan 2014 15:23 by ArcEye.

Please Log in or Create an account to join the conversation.

Time to create page: 0.091 seconds
Powered by Kunena Forum