NEC / Optiarc Writer Discuss, Bitsetting not working under linux ? at CD and DVD Writers forum; Hi all! Firstly great thanks for great work on NEC firmware! Today I bought a NEC ND 3520A and I can't seem to be able to set bitset. I downloaded http://www.micheldeboer.nl/firmware/LD3520_1U7.zip . Flashed my firmware successfully and : [~/Nec]> sudo ./necflash -s -scan Binflash - NEC version - (C) by

Old Posted: 09-03-2005
CartmanX (CD Freaks Junior Member)
Posts: 78
  • Find More Posts by CartmanX
Hi all!

Firstly great thanks for great work on NEC firmware! Today I bought a NEC ND 3520A and I can't seem to be able to set bitset. I downloaded http://www.micheldeboer.nl/firmware/LD3520_1U7.zip. Flashed my firmware successfully and :

[~/Nec]> sudo ./necflash -s -scan
Binflash - NEC version - (C) by Herrie and Liggy
Visit http://binflash.cdfreaks.com - http://www.herrie.org

List of supported devices:

Device : /dev/hdd
Vendor : _NEC
Model : DVD_RW ND-3520A
Firmware : 1.U7

[~/Nec]> sudo ./necflash -s -setbt DVD+R DVD-ROM perm /dev/hdd
Binflash - NEC version - (C) by Herrie and Liggy
Visit http://binflash.cdfreaks.com - http://www.herrie.org

Drivetype could not be determined


Here is the strace info for relevant part :
===============================
open("/dev/hdd", O_RDONLY|O_NONBLOCK) = 3
ioctl(3, SG_GET_VERSION_NUM, 0xbffff1b4) = 0
ioctl(3, SG_IO, 0x80ba2f8) = 0
ioctl(3, SG_IO, 0x80ba2f8) = 0
close(3) = 0
write(2, "Drivetype could not be determine"..., 34Drivetype could not be determined
) = 34
munmap(0xb7fff000, 4096) = 0
exit_group(12) = ?

===============================

System info :
Linux kernel 2.6.11 vanilla from kernel.org

Also note that I run program through sudo so I got write access to device.
default_avatar
Today (MyCE Staff)
Posts: 15,596
Old Posted: 09-03-2005
Liggy (CD Freaks System Admin)
Posts: 6,622
  • Find More Posts by Liggy
Quote:
Originally Posted by CartmanX
Hi all!

Firstly great thanks for great work on NEC firmware! Today I bought a NEC ND 3520A and I can't seem to be able to set bitset. I downloaded http://www.micheldeboer.nl/firmware/LD3520_1U7.zip. Flashed my firmware successfully and :

Drivetype could not be determined
===============================

System info :
Linux kernel 2.6.11 vanilla from kernel.org

Also note that I run program through sudo so I got write access to device.
It's hard to tell the exact reason, but something on your PC seems to prevent Binflash from sending a command that reads a specific flash region to determine your drivetype. I've read some threads that this may be related to the used kernel version.

Unfortunately there's nothing I can change in my program, as it's something else that prevents the flasher from sending the necessary commands to the drive.
__________________
You need to flash or dump your NEC DVD burner firmwares on your Mac, Windows, DOS or Linux machine? Just try Binflash.
Visit Liggy's and Dee's Optiarc and NEC firmware and tools page for all kind of information about NEC and Optiarc drives.


Unrequested PM about drive problems will not be answered!
Old Posted: 09-03-2005
CartmanX (CD Freaks Junior Member)
Posts: 78
  • Find More Posts by CartmanX
Quote:
Originally Posted by Liggy
Unfortunately there's nothing I can change in my program, as it's something else that prevents the flasher from sending the necessary commands to the drive.
Hi Liggy,

if you can send me the relevant part of your code ( only the part that does ioctl & error check ) I can try to find if kernel is buggy.

Thanks,
ismail
__________________
An Eye For Eye Will Make Whole World Blind
Old Posted: 10-03-2005
CartmanX (CD Freaks Junior Member)
Posts: 78
  • Find More Posts by CartmanX
Also note that flashing works so I bet there is something wrong with the code...
__________________
An Eye For Eye Will Make Whole World Blind
Old Posted: 10-03-2005
default_avatar
dnd (New on Forum)
Posts: 27
  • Find More Posts by dnd
Quote:
Drivetype could not be determined
This is the same error given when using the windows counterpart. Try to use something else to set the booktype.
Old Posted: 10-03-2005
CartmanX (CD Freaks Junior Member)
Posts: 78
  • Find More Posts by CartmanX
Quote:
Originally Posted by dnd
Try to use something else to set the booktype.
I have no Windows installed so what would be alternative?
__________________
An Eye For Eye Will Make Whole World Blind
Old Posted: 10-03-2005
Liggy (CD Freaks System Admin)
Posts: 6,622
  • Find More Posts by Liggy
Quote:
Originally Posted by CartmanX
Hi Liggy,

if you can send me the relevant part of your code ( only the part that does ioctl & error check ) I can try to find if kernel is buggy.

Thanks,
ismail
The relevant code for sending ioctl's was not written by me. You can check fPLSCSI yourself from here.
__________________
You need to flash or dump your NEC DVD burner firmwares on your Mac, Windows, DOS or Linux machine? Just try Binflash.
Visit Liggy's and Dee's Optiarc and NEC firmware and tools page for all kind of information about NEC and Optiarc drives.


Unrequested PM about drive problems will not be answered!
Old Posted: 10-03-2005
default_avatar
dnd (New on Forum)
Posts: 27
  • Find More Posts by dnd
Quote:
I have no Windows installed so what would be alternative?
Well, another linux software package, if there is one that works. It's been a long while since I played with linux, but how about dvd+rw-tools? It seems to be pretty popular, shouldn't be hard to find a binary package that works with your installation. The command would be something like "dvd+rw-booktype -dvd-rom -unit+r /dev/hdd" for you. Might not work, but worth a try.
Old Posted: 10-03-2005
CartmanX (CD Freaks Junior Member)
Posts: 78
  • Find More Posts by CartmanX
Quote:
Originally Posted by dnd
Well, I had in mind another linux software package, if there is one that works. It's been a long while since I played with linux, but how about dvd+rw-tools? It seems to be pretty popular, shouldn't be hard to find a binary package that works with your installation. I think the command is something like "dvd+rw-booktype -dvd-rom -unit+r /dev/hdd" for you. Might not work, but worth a try.
[cartman@southpark][13:25:01]
[~]> sudo dvd+rw-booktype -dvd-rom -unit+r /dev/hdd
:-[ RICOH(14h) failed with SK=5h/ASC=20h/ACQ=00h]: No such device

__________________
An Eye For Eye Will Make Whole World Blind
Old Posted: 10-03-2005
default_avatar
dnd (New on Forum)
Posts: 27
  • Find More Posts by dnd
Well, like I said everything linux related is a faded memory for me, but the tutorial for dvd+rw-tools mentions routing the command through the ide-scsi emulation, specifically

Quote:
If you have an IDE unit and run 2.4.x kernel, you most likely want to "route" it through ide-scsi emulation layer by either:

* passing "hdX=ide-scsi" argument to kernel;
* appending following lines to your /etc/modules.conf:

options ide-cd ignore=hdX
pre-install sg modprobe ide-scsi
pre-install sr_mod modprobe ide-scsi
pre-install ide-scsi modprobe ide-cd

Keep in mind that once hdX is routed through ide-scsi, you can no longer refer to /dev/hdX(*), but to corresponding /dev/scdN only.
I know you have 2.6 kernel but the doc might be outdated.
Old Posted: 10-03-2005
Liggy (CD Freaks System Admin)
Posts: 6,622
  • Find More Posts by Liggy
Quote:
Originally Posted by dnd
Well, another linux software package, if there is one that works. It's been a long while since I played with linux, but how about dvd+rw-tools? It seems to be pretty popular, shouldn't be hard to find a binary package that works with your installation. The command would be something like "dvd+rw-booktype -dvd-rom -unit+r /dev/hdd" for you. Might not work, but worth a try.
These DVD+RW tools only support Ricoh style bitsetting, but newer firmwares use their own NEC style command set for booktype changes and that one is not supported (yet?).
__________________
You need to flash or dump your NEC DVD burner firmwares on your Mac, Windows, DOS or Linux machine? Just try Binflash.
Visit Liggy's and Dee's Optiarc and NEC firmware and tools page for all kind of information about NEC and Optiarc drives.


Unrequested PM about drive problems will not be answered!
Old Posted: 10-03-2005
default_avatar
dnd (New on Forum)
Posts: 27
  • Find More Posts by dnd
Then I guess it doesn't work. Too bad.
Old Posted: 10-03-2005
CartmanX (CD Freaks Junior Member)
Posts: 78
  • Find More Posts by CartmanX
Quote:
Originally Posted by dnd
Well, like I said everything linux related is a faded memory for me, but the tutorial for dvd+rw-tools mentions routing the command through the ide-scsi emulation, specifically

I know you have 2.6 kernel but the doc might be outdated.
Thank you for your help but 2.6 kernel no longer uses ide-scsi interface for cd/dvd writing it now directly uses ide interface. Liggy suspects that real problem might be the fact that since 2.6.9 kernel some scsi commands are filtered ( those known to be dangerous ) . I don't know if those are filtered for root but I guess not. I am out of any clue for now.
__________________
An Eye For Eye Will Make Whole World Blind
Old Posted: 10-03-2005
CartmanX (CD Freaks Junior Member)
Posts: 78
  • Find More Posts by CartmanX
One other weird thing here is this :

ioctl(3, SG_IO, 0x80ba2f8) = 0
ioctl(3, SG_IO, 0x80ba2f8) = 0

Those ioctl commands return 0 which means ioctl succeeded but the program gives an error. Maybe a wrong if check there ( low possibility I know ... ) ?
__________________
An Eye For Eye Will Make Whole World Blind
Old Posted: 10-03-2005
Liggy (CD Freaks System Admin)
Posts: 6,622
  • Find More Posts by Liggy
Quote:
Originally Posted by CartmanX
One other weird thing here is this :

ioctl(3, SG_IO, 0x80ba2f8) = 0
ioctl(3, SG_IO, 0x80ba2f8) = 0

Those ioctl commands return 0 which means ioctl succeeded but the program gives an error. Maybe a wrong if check there ( low possibility I know ... ) ?
Found the bug. New version 1.12 will be published soon. Probably nobody was ever able to change the booktype on 3520 (and compatible) drives with binflash. *Searching for a big hole to hide*
__________________
You need to flash or dump your NEC DVD burner firmwares on your Mac, Windows, DOS or Linux machine? Just try Binflash.
Visit Liggy's and Dee's Optiarc and NEC firmware and tools page for all kind of information about NEC and Optiarc drives.


Unrequested PM about drive problems will not be answered!
Old Posted: 10-03-2005
CartmanX (CD Freaks Junior Member)
Posts: 78
  • Find More Posts by CartmanX
Quote:
Originally Posted by Liggy
Found the bug. New version 1.12 will be published soon. Probably nobody was ever able to change the booktype on 3520 (and compatible) drives with binflash. *Searching for a big hole to hide*
You might want to lock this topic and make it sticky . Cheers for great work!
__________________
An Eye For Eye Will Make Whole World Blind
Old Posted: 10-03-2005
CartmanX (CD Freaks Junior Member)
Posts: 78
  • Find More Posts by CartmanX
With 1.12 -setbt works fine but -querybt says :

Quote:
[~]> sudo ./necflash -s -querybt /dev/hdd
Binflash - NEC version - (C) by Herrie and Liggy
Visit http://binflash.cdfreaks.com - http://www.herrie.org

Currently no disc is inserted
The permanent booktype on DVD+R either has not been set or cannot be changed
The permanent booktype on DVD+RW either has not been set or cannot be changed
The permanent booktype on DVD+R-DL cannot be changed
A similar fix needed?
__________________
An Eye For Eye Will Make Whole World Blind
Old Posted: 10-03-2005
CartmanX (CD Freaks Junior Member)
Posts: 78
  • Find More Posts by CartmanX
When I put a dvd in. I get this :

[cartman@southpark][16:10:32]
[~/Nec]> sudo ./necflash -s -setbt DVD+R DVD-ROM perm /dev/hdd
Binflash - NEC version - (C) by Herrie and Liggy
Visit http://binflash.cdfreaks.com - http://www.herrie.org

[cartman@southpark][16:10:36]
[~/Nec]> sudo ./necflash -querybt /dev/hdd
Binflash - NEC version - (C) by Herrie and Liggy
Visit http://binflash.cdfreaks.com - http://www.herrie.org

The current disctype is DVD+R
The current booktype is DVD+R
The permanent booktype on DVD+R either has not been set or cannot be changed
The permanent booktype on DVD+RW either has not been set or cannot be changed
The permanent booktype on DVD+R-DL cannot be changed


Something going wrong here?
__________________
An Eye For Eye Will Make Whole World Blind
Old Posted: 10-03-2005
Liggy (CD Freaks System Admin)
Posts: 6,622
  • Find More Posts by Liggy
Quote:
Originally Posted by CartmanX
With 1.12 -setbt works fine but -querybt says :



A similar fix needed?
Nope. That must be something different. The drivetype is not checked here, I just issue NEC style commands first and if these fail I use the Ricoh one. What does strace tell you?
__________________
You need to flash or dump your NEC DVD burner firmwares on your Mac, Windows, DOS or Linux machine? Just try Binflash.
Visit Liggy's and Dee's Optiarc and NEC firmware and tools page for all kind of information about NEC and Optiarc drives.


Unrequested PM about drive problems will not be answered!
Old Posted: 10-03-2005
CartmanX (CD Freaks Junior Member)
Posts: 78
  • Find More Posts by CartmanX
Quote:
Originally Posted by Liggy
Nope. That must be something different. The drivetype is not checked here, I just issue NEC style commands first and if these fail I use the Ricoh one. What does strace tell you?
Ok first I assume you read http://club.cdfreaks.com/showpost.ph...8&postcount=18 is that normal? That DVD was written before I set to DVD-ROM so I guess its ok it shows book type as DVD+R ?

Here is output of beloved strace :

Quote:
open("/dev/hdd", O_RDWR|O_NONBLOCK) = 3
ioctl(3, SG_GET_VERSION_NUM, 0xbffff1c0) = 0
ioctl(3, SG_IO, 0x80c22f8) = 0
write(1, "The current disctype is DVD+R\n", 30The current disctype is DVD+R
) = 30
ioctl(3, SG_IO, 0x80c22f8) = 0
write(1, "The current booktype is DVD+R\n", 30The current booktype is DVD+R
) = 30
ioctl(3, SG_IO, 0x80c22f8) = 0
ioctl(3, SG_IO, 0x80c22f8) = 0
write(1, "The permanent booktype on DVD+R "..., 77The permanent booktype on DVD+R either has not been set or cannot be changed
) = 77
ioctl(3, SG_IO, 0x80c22f8) = 0
ioctl(3, SG_IO, 0x80c22f8) = 0
write(1, "The permanent booktype on DVD+RW"..., 78The permanent booktype on DVD+RW either has not been set or cannot be changed
) = 78open("/dev/hdd", O_RDWR|O_NONBLOCK) = 3
ioctl(3, SG_GET_VERSION_NUM, 0xbffff1c0) = 0
ioctl(3, SG_IO, 0x80c22f8) = 0
write(1, "The current disctype is DVD+R\n", 30The current disctype is DVD+R
) = 30
ioctl(3, SG_IO, 0x80c22f8) = 0
write(1, "The current booktype is DVD+R\n", 30The current booktype is DVD+R
) = 30
ioctl(3, SG_IO, 0x80c22f8) = 0
ioctl(3, SG_IO, 0x80c22f8) = 0
write(1, "The permanent booktype on DVD+R "..., 77The permanent booktype on DVD+R either has not been set or cannot be changed
) = 77
ioctl(3, SG_IO, 0x80c22f8) = 0
ioctl(3, SG_IO, 0x80c22f8) = 0
write(1, "The permanent booktype on DVD+RW"..., 78The permanent booktype on DVD+RW either has not been set or cannot be changed
) = 78
ioctl(3, SG_IO, 0x80c22f8) = 0
write(1, "The permanent booktype on DVD+R-"..., 53The permanent booktype on DVD+R-DL cannot be changed
) = 53
ioctl(3, SG_IO, 0x80c22f8) = 0
ioctl(3, SG_IO, 0x80c22f8) = 0
ioctl(3, SG_IO, 0x80c22f8) = 0
close(3) = 0

ioctl(3, SG_IO, 0x80c22f8) = 0
write(1, "The permanent booktype on DVD+R-"..., 53The permanent booktype on DVD+R-DL cannot be changed
) = 53
ioctl(3, SG_IO, 0x80c22f8) = 0
ioctl(3, SG_IO, 0x80c22f8) = 0
ioctl(3, SG_IO, 0x80c22f8) = 0
close(3) = 0
__________________
An Eye For Eye Will Make Whole World Blind
Old Posted: 10-03-2005
Liggy (CD Freaks System Admin)
Posts: 6,622
  • Find More Posts by Liggy
It seems strace doesn't really help. Even if a command fails, we seem to get rc=0.
Old Posted: 10-03-2005
CartmanX (CD Freaks Junior Member)
Posts: 78
  • Find More Posts by CartmanX
Quote:
Originally Posted by Liggy
It seems strace doesn't really help. Even if a command fails, we seem to get rc=0.
Another way would be adding some debugging statement like :

printf("Possible error : %s",strerror(errno));

This will print : "Possible Error : success" in case of no-error and will print error otherwise. But I rc = 0 means errno = 0 which is success.

Btw sorry for asking maybe third time but it says inserted DVD's current booktype is DVD+R . Is that normal? Because I set booktype to DVD-ROM for DVD+R,DVD+R-DL and DVD+RW but that dvd is written before I set booktype.
__________________
An Eye For Eye Will Make Whole World Blind
Old Posted: 10-03-2005
Liggy (CD Freaks System Admin)
Posts: 6,622
  • Find More Posts by Liggy
If the disc was written before, then the booktype on your disc is DVD+R and cannot be changed anymore. That's completely normal. But discs that you've written after changing the booktype should show a different value.
__________________
You need to flash or dump your NEC DVD burner firmwares on your Mac, Windows, DOS or Linux machine? Just try Binflash.
Visit Liggy's and Dee's Optiarc and NEC firmware and tools page for all kind of information about NEC and Optiarc drives.


Unrequested PM about drive problems will not be answered!
Old Posted: 10-03-2005
CartmanX (CD Freaks Junior Member)
Posts: 78
  • Find More Posts by CartmanX
Quote:
Originally Posted by Liggy
If the disc was written before, then the booktype on your disc is DVD+R and cannot be changed anymore. That's completely normal. But discs that you've written after changing the booktype should show a different value.
Thanks for the reply .
__________________
An Eye For Eye Will Make Whole World Blind
WIN your own LG N2B1 NAS with 2TB of Storage!*

To win, tell us why you want to win and tell ,or show us (graphic, video, etc.) why you think Life's Good with LG NAS.
*US only  Not registered yet? Register now!

Hello guest,
default
To benefit from all extra features you need to log in or sign up.

Search this Thread

New Posts

Posting Rules

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

People who found this also searched for

  • -[ get configuration failed with sk=5h asc=20h acq=00h] no such device
  • binflash drivetype could not be determined
  • bitset linux
  • bitsetting dvd linux
  • bitsetting linux kernel
  • bitsettings dvd-rom linux
  • booktype bitsetting
  • drivetype cannot be determined with binflash
  • drivetype cannot be determined with binflash help
  • drivetype could not be determined necflash
  • dvd bitsetting linux
  • dvd booktype no such device
  • dvd rom not working linux
  • dvd+rw-tools no such device
  • dvd-rom bitsetting linux dvd+r dl
  • linux atomic bit set
  • linux atomic bitset
  • linux bitset
  • linux bitsetting
  • linux dvd bitsetting
  • linux dvd+rw-booktype no such device
  • linux ioctl scsi sg get version num
  • sg get version num
  • sg io dvd+r
  • sg io problem
  • sg io set booktype
  • sk=5h asc=20h acq=00h
All times are GMT +2. The time now is 06:19.
Top